package com.he.starter1.use;

import com.alibaba.fastjson.JSON;
import com.he.starter1.prop.DogProp;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.context.properties.EnableConfigurationProperties;
import org.springframework.stereotype.Component;

/**
 * @author heyanjing
 * date:2020-03-12 2020/3/12:11:54
 */
@Slf4j
@Component
@EnableConfigurationProperties(DogProp.class)
public class UserDogProp {

    @Autowired
    private DogProp dogProp;

    public DogProp show() {
        log.info("{}", JSON.toJSONString(dogProp));
        return dogProp;
    }

}
